/*
TODO implement breaking sounds. shoot and hit should start right away, breking the execution of any other sound
*/

#ifndef Sound_h
#define Sound_h

#include "Tone.h"
//based on
//http://code.google.com/p/rogue-code/wiki/ToneLibrary

class Sound :  
public Tone {

struct Note {
  int pitch;
  int duration;
};

public: 
  boolean playing;
  int nCurrentNote;
  int noteBufferMax;
  Note noteBuffer[255];   // Pointer to note struct, initialize to nothing.

  void setMelody(Note & melodyAdress,int nNotes);
  void refreshStatus();
  void shoot();
  void respawning();
  void playerReady();
  void death();
  void hit();
  void gameOver();
  void respawnStart();
  void outOfAmmo();
  void nearMiss();
  void startedReloading();
  void finishedReloading();
};
#endif




